import axios from '@/api/fetch';
import SERVER from '@/api/server';

// GET 查询列表 /vsSalesReport/searchReportForDealer
export const queryList = (params) => axios.get(`${SERVER.RETAIL}/vsSalesReport/searchReportForDealer`, {
  params
})

// GET 导出 /vsSalesReport/searchReportForDealerExcel
export const exportExcel = (params) => axios.post(`${SERVER.RETAIL}/vsSalesReport/searchReportForDealerExcel`, params, {
  responseType: 'blob'
});
// export const exportExcel = (params) => axios.get(`${SERVER.RETAIL}/vsSalesReport/searchReportForDealerExcel`, {
//   params,
//   responseType: 'arraybuffer'
// })

// GET 查询详情  /vsSalesReport/searchRetailOrderReportDataById
export const getInfoById = (Id) => axios.get(`${SERVER.RETAIL}/vsSalesReport/searchRetailOrderReportDataById?id=${Id}`)

// 零售订单维护	查询销售顾问	sysmanage	 /employeeNew/getEmployees	get
export const getEmployees = (params) => axios.get(`${SERVER.SYSMANAGE}/employeeNew/getEmployees`, {
  params
});
// / 导出
export const exporturl = params => axios.post(`/api/cmscloud.excel/downloadExcel/exportExcel/${params.CODE}`, params);
